package com.lcz.manage.util.event.publisher.impl;

import java.util.concurrent.Executor;

import javax.annotation.PostConstruct;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import com.lcz.manage.util.event.publisher.enums.PublisherType;
import com.lcz.manage.util.event.publisher.factory.EventPublisherFactory;

import lombok.extern.slf4j.Slf4j;

/**
 * @author xingyongjiang@yunrong.cn
 * @version V3.0
 * @since 2021/4/19 13:21
 */
@Slf4j
@Component
public class SyncApplicationEventPublisher extends AbstractEventPublisher {

    @Autowired
    private EventPublisherFactory eventPublisherFactory;

    @PostConstruct
    public void init() {
        //注册
        eventPublisherFactory.register(PublisherType.SYNC.getCode(), this);
    }

    @Override
    protected Executor getExecutor() {
        return null;
    }
}
